package com.ruoyi.system.service.impl;

import com.github.pagehelper.PageHelper;
import com.ruoyi.system.domain.Couch;
import com.ruoyi.system.mapper.CouchMapper;
import com.ruoyi.system.service.ICoachService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.ArrayList;
import java.util.List;

/**
 * @author Ly lilongfei
 * @date 2024/6/27
 * @Description
 */
@Service
public class CoachServiceImpl implements ICoachService {

    @Autowired
    private CouchMapper couchMapper;

    @Override
    public List<Couch> findAll(int page, int size) {
        PageHelper.startPage(page, size);
        return couchMapper.findAllCouch();
    }

    @Override
    public List<Couch> findCouchListByProject(int projectId) {
        return couchMapper.selectCouchByProjectId(projectId);
    }
}
